package com.xxxx.comment.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.xxxx.comment.entity.Follow;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author 虎哥
 * @since 2021-12-22
 */
@Mapper
public interface FollowMapper extends BaseMapper<Follow> {

    Boolean isFollow(@Param("userId") Long userId, @Param("followUserId") Long followUserId);

    Follow getFollow(@Param("followUserId") Long followUserId, @Param("userId") Long userId);

    Boolean unFollow(@Param("id") Long id);

    List<Follow> getByFollowUserId(@Param("followUserId") Long followUserId);

}
